package org.zanpu.metadataserver.core.dbmanager;

import org.apache.commons.lang3.StringUtils;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * Created by MD on 2016/11/4.
 */
public class InsertVo {
    private Map<String,Object> map;
    private String tableName;
    private String values;

    public InsertVo(){}
    public InsertVo(String tableName, String values){
        this.tableName = tableName;
        this.values = values;
    }

    public static Map<String,Object> build(String tableName,String values){
        return new InsertVo(tableName,values).getMap();
    }

    public String getTableName() {
        return tableName;
    }

    public void setTableName(String tableName) {
        this.tableName = tableName;
    }

    public String getValues() {
        return values;
    }

    public void setValues(String values) {
        this.values = values;
    }

    public Map<String,Object> getMap(){
        map = new HashMap<String,Object>();
        map.put("id",null);
        map.put("table",tableName);
        map.put("values",values);
        return map;
    }
}
